using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._DataManagementTools._LASDataset
{
    /// <summary>
    /// <para>Create LAS Dataset</para>
    /// <para>Creates a LAS dataset referencing one or more LAS files and optional surface constraint features.</para>
    /// <para>创建引用一个或多个 LAS 文件和可选曲面约束要素的 LAS 数据集。</para>
    /// </summary>    
    [DisplayName("Create LAS Dataset")]
    public class CreateLasDataset : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public CreateLasDataset()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_input">
        /// <para>Input Files</para>
        /// <para><xdoc>
        ///   <para>The LAS files and folders containing LAS files that will be referenced by the LAS dataset.</para>
        ///   <para>In the tool dialog box, a folder can also be specified as an input by selecting the folder in Windows Explorer and dragging it onto the parameter's input box.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>LAS 数据集将引用的 LAS 文件和包含 LAS 文件的文件夹。</para>
        ///   <para>在工具对话框中，还可以通过在 Windows 资源管理器中选择文件夹并将其拖动到参数的输入框中，将文件夹指定为输入。</para>
        /// </xdoc></para>
        /// </param>
        /// <param name="_out_las_dataset">
        /// <para>Output LAS Dataset</para>
        /// <para>The LAS dataset that will be created.</para>
        /// <para>将创建的 LAS 数据集。</para>
        /// </param>
        public CreateLasDataset(List<object> _input, object _out_las_dataset)
        {
            this._input = _input;
            this._out_las_dataset = _out_las_dataset;
        }
        public override string ToolboxName => "Data Management Tools";

        public override string ToolName => "Create LAS Dataset";

        public override string CallName => "management.CreateLasDataset";

        public override List<string> AcceptEnvironments => ["outputCoordinateSystem", "workspace"];

        public override object[] ParameterInfo => [_input, _out_las_dataset, _folder_recursion.GetGPValue(), _in_surface_constraints, _spatial_reference, _compute_stats.GetGPValue(), _relative_paths.GetGPValue(), _create_las_prj.GetGPValue()];

        /// <summary>
        /// <para>Input Files</para>
        /// <para><xdoc>
        ///   <para>The LAS files and folders containing LAS files that will be referenced by the LAS dataset.</para>
        ///   <para>In the tool dialog box, a folder can also be specified as an input by selecting the folder in Windows Explorer and dragging it onto the parameter's input box.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>LAS 数据集将引用的 LAS 文件和包含 LAS 文件的文件夹。</para>
        ///   <para>在工具对话框中，还可以通过在 Windows 资源管理器中选择文件夹并将其拖动到参数的输入框中，将文件夹指定为输入。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Files")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public List<object> _input { get; set; }


        /// <summary>
        /// <para>Output LAS Dataset</para>
        /// <para>The LAS dataset that will be created.</para>
        /// <para>将创建的 LAS 数据集。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output LAS Dataset")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_las_dataset { get; set; }


        /// <summary>
        /// <para>Include subfolders</para>
        /// <para><xdoc>
        ///   <para>Specifies whether .las files residing in the subdirectories of an input folder will be referenced by the LAS dataset.</para>
        ///   <bulletList>
        ///     <bullet_item>Unchecked—Only .las files residing in an input folder will be added to the LAS dataset. This is the default.</bullet_item><para/>
        ///     <bullet_item>Checked—All .las files residing in the subdirectories of an input folder will be added to the LAS dataset.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定 LAS 数据集是否引用驻留在输入文件夹的子目录中的 .las 文件。</para>
        ///   <bulletList>
        ///     <bullet_item>未选中 - 仅将驻留在输入文件夹中的 .las 文件添加到 LAS 数据集中。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>选中 - 驻留在输入文件夹子目录中的所有 .las 文件都将添加到 LAS 数据集中。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Include subfolders")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _folder_recursion_value _folder_recursion { get; set; } = _folder_recursion_value._false;

        public enum _folder_recursion_value
        {
            /// <summary>
            /// <para>RECURSION</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("RECURSION")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NO_RECURSION</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NO_RECURSION")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Surface Constraints</para>
        /// <para><xdoc>
        ///   <para>The features that will contribute to the definition of the triangulated surface generated from the LAS dataset.</para>
        ///   <bulletList>
        ///     <bullet_item>Input Features—The features with geometry that will be incorporated into the LAS dataset's triangulated surface.</bullet_item><para/>
        ///     <bullet_item>Height Field—The feature's elevation source can be derived from any numeric field in the feature's attribute table or the geometry by selecting Shape.Z. If no height is necessary, specify the keyword <None> to create z-less features with elevation that will be interpolated from the surface.</bullet_item><para/>
        ///     <bullet_item>Type—Defines the feature's role in the triangulated surface generated from the LAS dataset. Options with hard or soft designation refer to whether the feature edges represent distinct breaks in slope or a gradual change.</bullet_item><para/>
        ///     <bullet_item>Surface Feature Type—The surface feature type that defines how the feature geometry will be incorporated into the triangulation for the surface. Options with hard or soft designation refer to whether the feature edges represent distinct breaks in slope or a gradual change.
        ///     <bulletList>
        ///       <bullet_item>anchorpoints—Elevation points that will not be thinned away. This option is only available for single-point feature geometry.  </bullet_item><para/>
        ///       <bullet_item>hardline or softline—Breaklines that enforce a height value.  </bullet_item><para/>
        ///       <bullet_item>hardclip or softclip—Polygon dataset that defines the boundary of the LAS dataset.  </bullet_item><para/>
        ///       <bullet_item>harderase or softerase—Polygon dataset that defines holes in the LAS dataset.  </bullet_item><para/>
        ///       <bullet_item>hardreplace or softreplace—Polygon dataset that defines areas of constant height.  </bullet_item><para/>
        ///     </bulletList>
        ///     </bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>有助于定义从 LAS 数据集生成的三角剖分曲面的要素。</para>
        ///   <bulletList>
        ///     <bullet_item>输入要素 - 将合并到 LAS 数据集三角化曲面的几何要素。</bullet_item><para/>
        /// <bullet_item>高度字段 - 要素的高程源可从要素属性表中的任何数值字段或几何中派生，方法是选择 Shape.Z。如果不需要高度，则指定关键字<None>以创建具有将从表面插值的高程的无 z 要素。</bullet_item><para/>
        ///     <bullet_item>类型 - 定义要素在根据 LAS 数据集生成的三角化曲面中的角色。具有硬或软名称的选项是指要素边是表示斜率中的明显断裂还是渐变。</bullet_item><para/>
        /// <bullet_item>曲面要素类型 （Surface Feature Type） - 定义如何将要素几何合并到曲面三角剖分中的曲面要素类型。具有硬或软名称的选项是指要素边是表示斜率中的明显断裂还是渐变。
        ///     <bulletList>
        ///       <bullet_item>锚点 - 不会细化的高程点。此选项仅适用于单点要素几何。 </bullet_item><para/>
        ///       <bullet_item>hardline 或 softline - 强制执行高度值的分隔线。</bullet_item><para/>
        ///       <bullet_item>硬裁剪或软裁剪 - 定义 LAS 数据集边界的面数据集。</bullet_item><para/>
        ///       <bullet_item>harderase 或 softerase - 定义 LAS 数据集中的孔的面数据集。</bullet_item><para/>
        ///       <bullet_item>hardreplace 或 softreplace—定义恒定高度区域的面数据集。</bullet_item><para/>
        ///     </bulletList>
        ///     </bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Surface Constraints")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _in_surface_constraints { get; set; } = null;


        /// <summary>
        /// <para>Coordinate System</para>
        /// <para>The spatial reference of the LAS dataset. If no spatial reference is explicitly assigned, the LAS dataset will use the coordinate system of the first input LAS file. If the input files do not contain any spatial reference information and the Input Coordinate System is not set, then the LAS dataset's coordinate system will be listed as unknown.</para>
        /// <para>LAS 数据集的空间参考。如果未显式指定空间参考，则 LAS 数据集将使用第一个输入 LAS 文件的坐标系。如果输入文件不包含任何空间参考信息且未设置输入坐标系，则 LAS 数据集的坐标系将列为未知。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Coordinate System")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _spatial_reference { get; set; } = null;


        /// <summary>
        /// <para>Compute Statistics</para>
        /// <para><xdoc>
        ///   <para>Specifies whether statistics for the LAS files will be computed and a spatial index generated for the LAS dataset. The presence of statistics allows the LAS dataset layer's filtering and symbology options to only show LAS attribute values that exist in the LAS files. A .lasx auxiliary file is created for each LAS file.</para>
        ///   <bulletList>
        ///     <bullet_item>Unchecked—Statistics will not be computed. This is the default.</bullet_item><para/>
        ///     <bullet_item>Checked—Statistics will be computed.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定是否计算 LAS 文件的统计数据以及为 LAS 数据集生成空间索引。统计数据的存在允许 LAS 数据集图层的过滤和符号系统选项仅显示 LAS 文件中存在的 LAS 属性值。将为每个 LAS 文件创建一个 .lasx 辅助文件。</para>
        ///   <bulletList>
        ///     <bullet_item>未选中—不计算统计数据。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>选中—将计算统计数据。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Compute Statistics")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _compute_stats_value _compute_stats { get; set; } = _compute_stats_value._true;

        public enum _compute_stats_value
        {
            /// <summary>
            /// <para>COMPUTE_STATS</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("COMPUTE_STATS")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NO_COMPUTE_STATS</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NO_COMPUTE_STATS")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Store Relative Paths</para>
        /// <para><xdoc>
        ///   <para>Specifies whether lidar files and surface constraint features will be referenced by the LAS dataset through relative or absolute paths. Using relative paths may be convenient for cases where the LAS dataset and its associated data will be relocated in the file system using the same relative location to one another.</para>
        ///   <bulletList>
        ///     <bullet_item>Unchecked—Absolute paths will be used for the data referenced by the LAS dataset. This is the default.</bullet_item><para/>
        ///     <bullet_item>Checked—Relative paths will be used for the data referenced by the LAS dataset.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定 LAS 数据集是通过相对路径还是绝对路径参照激光雷达文件和曲面约束要素。对于将 LAS 数据集及其关联数据使用彼此相同的相对位置重新定位到文件系统中的情况，使用相对路径可能很方便。</para>
        ///   <bulletList>
        ///     <bullet_item>未选中—绝对路径将用于 LAS 数据集所引用的数据。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>选中 - 相对路径将用于 LAS 数据集所引用的数据。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Store Relative Paths")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _relative_paths_value _relative_paths { get; set; } = _relative_paths_value._false;

        public enum _relative_paths_value
        {
            /// <summary>
            /// <para>RELATIVE_PATHS</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("RELATIVE_PATHS")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>ABSOLUTE_PATHS</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("ABSOLUTE_PATHS")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Create PRJ For LAS Files</para>
        /// <para><xdoc>
        ///   <para>Specifies whether .prj files will be created for the LAS files referenced by the LAS dataset.</para>
        ///   <bulletList>
        ///     <bullet_item>No LAS Files—No files will have a PRJ file created. This is the default.</bullet_item><para/>
        ///     <bullet_item>Files with Missing Spatial References—Only LAS files without a spatial reference will have a corresponding PRJ file.</bullet_item><para/>
        ///     <bullet_item>All LAS Files—All LAS files will have a corresponding PRJ file.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定是否为 LAS 数据集引用的 LAS 文件创建 .prj 文件。</para>
        ///   <bulletList>
        ///     <bullet_item>无 LAS 文件—不会创建任何文件的 PRJ 文件。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>缺少空间参考的文件 - 只有没有空间参考的 LAS 文件才会具有相应的 PRJ 文件。</bullet_item><para/>
        ///     <bullet_item>所有 LAS 文件—所有 LAS 文件都将具有相应的 PRJ 文件。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Create PRJ For LAS Files")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _create_las_prj_value _create_las_prj { get; set; } = _create_las_prj_value._NO_FILES;

        public enum _create_las_prj_value
        {
            /// <summary>
            /// <para>No LAS Files</para>
            /// <para>No LAS Files—No files will have a PRJ file created. This is the default.</para>
            /// <para>无 LAS 文件—不会创建任何文件的 PRJ 文件。这是默认设置。</para>
            /// </summary>
            [Description("No LAS Files")]
            [GPEnumValue("NO_FILES")]
            _NO_FILES,

            /// <summary>
            /// <para>Files with Missing Spatial References</para>
            /// <para>Files with Missing Spatial References—Only LAS files without a spatial reference will have a corresponding PRJ file.</para>
            /// <para>缺少空间参考的文件 - 只有没有空间参考的 LAS 文件才会具有相应的 PRJ 文件。</para>
            /// </summary>
            [Description("Files with Missing Spatial References")]
            [GPEnumValue("FILES_MISSING_PROJECTION")]
            _FILES_MISSING_PROJECTION,

            /// <summary>
            /// <para>All LAS Files</para>
            /// <para>All LAS Files—All LAS files will have a corresponding PRJ file.</para>
            /// <para>所有 LAS 文件—所有 LAS 文件都将具有相应的 PRJ 文件。</para>
            /// </summary>
            [Description("All LAS Files")]
            [GPEnumValue("ALL_FILES")]
            _ALL_FILES,

        }

        public CreateLasDataset SetEnv(object outputCoordinateSystem = null, object workspace = null)
        {
            base.SetEnv(outputCoordinateSystem: outputCoordinateSystem, workspace: workspace);
            return this;
        }

    }

}